Skip to content

[chore] add typed error for executor#867

Merged
ipaqsa merged 2 commits intomainfrom
feature/stderr-custom-error-type
Apr 15, 2026
Merged

[chore] add typed error for executor#867
ipaqsa merged 2 commits intomainfrom
feature/stderr-custom-error-type

Conversation

@Fkuloff
Copy link
Copy Markdown
Contributor

@Fkuloff Fkuloff commented Apr 13, 2026

Overview

Replace fmt.Errorf("stderr: ...") with a custom StderrError type in RunAndLogLines. Callers can use errors.As to detect stderr errors and access raw content without brittle string prefix trimming. Error() returns the same string format — fully backward compatible.

What this PR does / why we need it

@Fkuloff Fkuloff requested a review from ipaqsa April 13, 2026 11:20
@Fkuloff Fkuloff marked this pull request as ready for review April 13, 2026 11:21
@Fkuloff Fkuloff self-assigned this Apr 13, 2026
@ipaqsa ipaqsa changed the title [shell-operator] add StderrError type for typed stderr error handling [chore] add typed error for executor Apr 13, 2026
@ipaqsa ipaqsa marked this pull request as draft April 13, 2026 11:41
@ipaqsa ipaqsa requested a review from ldmonster April 13, 2026 11:41
@ipaqsa ipaqsa added enhancement New feature or request go Pull requests that update Go code labels Apr 13, 2026
@Fkuloff Fkuloff marked this pull request as ready for review April 14, 2026 08:54
Comment thread pkg/executor/executor.go Outdated
Comment thread pkg/executor/executor.go Outdated
@ipaqsa ipaqsa merged commit 448ee96 into main Apr 15, 2026
9 checks passed
@ipaqsa ipaqsa deleted the feature/stderr-custom-error-type branch April 15, 2026 10:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request go Pull requests that update Go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants